#pragma once
#include "atlwin.h"

#import "../../bin-VS6/XSPhoneActiveX.ocx" no_namespace
//no_namespace, raw_interfaces_only
using namespace ATL;

class SpcWraperDlg;
extern _ATL_FUNC_INFO OnScreenPopDataArrivalInfo;
class CSoftPhoneWrapper :public CAxWindow,
	public IDispEventSimpleImpl<1, CSoftPhoneWrapper, &__uuidof(_DXSPhoneActiveXEvents)>
{
public:
	CSoftPhoneWrapper();
	~CSoftPhoneWrapper();
	CComQIPtr<_DXSPhoneActiveX> m_SPCControl;
	BEGIN_SINK_MAP(CSoftPhoneWrapper)
		SINK_ENTRY_INFO(1, __uuidof(_DXSPhoneActiveXEvents), 1, OnScreenPopDataArrival, &OnScreenPopDataArrivalInfo)
	END_SINK_MAP()
	SpcWraperDlg* m_parentDlg;
	HWND Create(
		_In_opt_ HWND hWndParent,
		_In_ _U_RECT rect = NULL,
		_In_opt_z_ LPCTSTR szWindowName = NULL,
		_In_ DWORD dwStyle = 0,
		_In_ DWORD dwExStyle = 0,
		_In_ _U_MENUorID MenuOrID = 0U,
		_In_opt_ LPVOID lpCreateParam = NULL);
	BOOL DestoryWindow();
	STDMETHOD(OnScreenPopDataArrival)(BSTR strEvtMsg);

};

